package com.yh.correct.model;

import javax.validation.constraints.Pattern;

import org.hibernate.validator.constraints.NotBlank;

/**
 * t_judicial_deptment 司法所表对应的实体类
 * @author Administrator
 *
 */
public class JudicialDeptment {
	/**
	 * 司法所id
	 */
	private Integer id;
	/**
	 * 司法所名称
	 */
	@NotBlank(message="司法所名称不能为空")
	private String name;
	/**
	 * 地理位置
	 */
	@NotBlank(message="地理位置不能为空")
	private String location;
	/**
	 * 负责人姓名
	 */
	@NotBlank(message="负责人姓名不能为空")
	private String principal;
	/**
	 * 负责人电话
	 */
	@Pattern(regexp = "\\d{11}|",message="手机号码格式不正确")
	private String phonenum;
	public Integer getId() {
		return id;
	}
	public void setId(Integer id) {
		this.id = id;
	}
	public String getName() {
		return name;
	}
	public void setName(String name) {
		this.name = name;
	}
	public String getLocation() {
		return location;
	}
	public void setLocation(String location) {
		this.location = location;
	}
	public String getPrincipal() {
		return principal;
	}
	public void setPrincipal(String principal) {
		this.principal = principal;
	}
	public String getPhonenum() {
		return phonenum;
	}
	public void setPhonenum(String phonenum) {
		this.phonenum = phonenum;
	}
	@Override
	public String toString() {
		return "JudicialDeptment [id=" + id + ", name=" + name + ", location=" + location + ", principal=" + principal
				+ ", phonenum=" + phonenum + "]";
	}
	
}
